<template>
  <div class="box"></div>
</template>

<script setup lang='ts'>
import { ref, reactive, inject } from 'vue'
const colorVal = inject('colorVal')

</script>

<style lang='scss' scoped>
.box {
  width: 100px;
  height: 100px;
  background-color: v-bind(colorVal);
}

</style>